import request from '@/utils/request'
export function getRoleList (params) {
    return request({
        url: '/sys/role',
        params
    })
}
export function delRole (id) {
    return request({
        url: `/sys/role/${id}`,
        method: 'delete'
    })
}
export function addRole (data) {
    return request({
        url: `/sys/role`,
        data,
        method: 'post'
    })
}
export function updateRole (data) {
    return request({
        url: `/sys/role/${data.id}`,
        data,
        method: 'put'
    })
}

export function getRoleDetail (id) {
    return request({
        url: `/sys/role/${id}`,
    })
}

export function getCompanyInfo () {
    return request({
        url: `/company`,
    })
}